package com.haiya.identityaccess.infrastructure.persistence.mybatis.mapper;

import com.haiya.db.mapper.SuperMapper;
import com.haiya.identityaccess.infrastructure.persistence.mybatis.datamodel.DataRole;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @author qiaoguoqiang
 */
@Mapper
public interface RoleMapper extends SuperMapper<DataRole> {
    List<DataRole> allRoles(@Param("tenantId") String tenantId);
    void removeNamed(@Param("tenantId") String tenantId, @Param("name") String name);
    DataRole roleNamed(@Param("tenantId") String tenantId, @Param("name") String name);
}
